<%@ page contentType="text/html; charset=ISO-8859-1" language="java" pageEncoding="ISO-8859-1"%>
<%@ taglib prefix="s" uri="/struts-tags" %>
<%@ page import="model.ServiceCall" %>

<!DOCTYPE html>
<html>
<head>
	<title>Service call list</title>
</head>
<body>
	<h2>Service call list</h2>
	
    <table>
		<thead>
			<tr>
   				<th>ID</th>
   				<th>Customer</th>
   				<th>Product</th>
   				<th>Description</th>
   				<th>Priority Code</th>
   				<th>Status Code</th>
   				<th>Operator</th>
   				<th>Start time</th>
   				<th>Stop time</th>
			</tr>
		</thead>
		<tbody>
			<s:iterator value="serviceCalls">
				<tr>
					<td><s:property value="id" /></td>
					<td><s:property value="customer.name" />
					<td><s:property value="product.description" />
					<td><s:property value="description" />
					<td><s:property value="priority" />
					<td><s:property value="status" />
					<td><s:property value="operator.name" />
					<td><s:property value="startTime" />
					<td><s:property value="stopTime" />
					
					<!-- Service call list -->
					<s:url id="serviceCallEditUrl" action="ServiceCallEditAction">
    					<s:param name="id" value="%{id}" />
					</s:url>
					<s:a href="%{serviceCallEditUrl}">Edit</s:a>
				</tr>
			</s:iterator>
		</tbody>
	</table>    
</body>
</html>